nanopyx.core.transform.sr_3D_radial_gradient_convergence

class RadialGradientConvergence3D:
RadialGradientConvergence3D()

Calculate the Radial Gradient Convergence (RGC) of an image.

Parameters
  • magnification: magnification of the image
  • radius: radius of the RGC (the PSF Full-Width-Half-Maximum)
  • sensitivity: sensitivity of the RGC (sharpening factor)
  • doIntensityWeighting: whether to do intensity weighting
def calculate(*args, **kwargs):
18    def wrapper(*args, **kwargs):
19        start = time.time()
20        result = func(*args, **kwargs)
21        end = time.time()
22        delta = end - start
23        if delta < 10**-4:
24            msg = f"{func.__name__} took {delta/1e-6:.6f} nseconds"
25        elif delta < 10**-1:
26            msg = f"{func.__name__} took {delta/1e-3:.6f} mseconds"
27        else:
28            msg = f"{func.__name__} took {delta:.6f} seconds"
29        print(msg)
30        return result